"""
自动化测试放弃页面要操作哪些元素，就封装哪些方法
"""
from base.base import Base
usrname=("name","username")
pwd=("name","password")
ver=("name","verify_code")
denglu=("xpath", "//*[@id='loginform']/div/div[6]/a")
phone=("xpath","/html/body/div[3]/div/div[2]/div[2]/div[1]/div[2]/a[1]")
class Pagelogin(Base):
    def page_username(self,value):
        self.base_input(usrname,value)
    def page_pwd(self,value):
        self.base_input(pwd,value)
    def page_ver(self,value):
        self.base_input(ver,value)
    def page_denglu(self):
        self.base_find(denglu).click()
    def page_text(self):
        return self.base_find(phone).text
    def page_login(self,ph,pw,ve):
        self.page_username(ph)
        self.page_pwd(pw)
        self.page_ver(ve)
        self.page_denglu()